﻿@model PhoneBilling.Models.GroupEditModel
@{
    ViewBag.Title = "分组编辑";
    Layout = "~/Views/Shared/_Layout.cshtml";
}
<script type="text/javascript">
    $(document).ready(function () {
        $("#btnConfirm").ligerButton(
        {
            click: function () {
                $('form').submit();
            }
        });
    });
    
</script>
@using (Html.BeginForm())
{ 
    <div >
        <div class="input-text">
            @{if (Model.ParentType == "Department")
              { 
                @Html.LabelFor(m => m.Department)
                @Html.DisplayFor(m => m.Department)
                @Html.HiddenFor(m => m.Department)
              }
              else if (Model.ParentType == "Group")
              {
                @Html.LabelFor(m => m.Group)
                @Html.DisplayFor(m => m.Group)
                @Html.HiddenFor(m => m.Group)
              }
            }
        </div>
             @Html.HiddenFor(m => m.IsNew)
             @Html.HiddenFor(m => m.ParentID)
             @Html.HiddenFor(m => m.ParentType)
             @Html.HiddenFor(m => m.ID)
        <div class="input-text">
             @Html.LabelFor(m => m.名称)
             @Html.TextBoxFor(m => m.名称)
             @Html.ValidationMessageFor(m => m.名称, new { style = "color:Red" })
        </div>
        <div class="input-text">
             @Html.LabelFor(m => m.收费等级)
             @Html.DropDownListFor(m => m.收费等级, new SelectList(Model.GradeList, "ID", "Name"), new { style = "input-text" })
             @Html.ValidationMessageFor(m => m.收费等级, new { style = "color:Red" })
        </div>
        <p class="submit">
            <input type="button" id="btnConfirm" value="确定" />
        </p>
    </div>
}

